package edu.wust;

public class No1exam9 {


    public static void main(String[] args){
        int n = 1000;
        out:
        for (int i = 1; i < n/2;i++) {
            for (int j = i + 1; j < n-i; j++) {
                int k = n - i - j;
                if (i * i + j * j == k * k) {
                    System.out.println(i * j * k);
                    break out;
                }
            }
        }


    }
}
